import { Component } from '@angular/core';
import { IonicPage, NavController, NavParams } from 'ionic-angular';
import { LoginPage } from '../login/login';
import { RegisterPage} from '../register/register';
import {HomePage} from '../home/home';
import { TabsPage } from '../tabs/tabs';
/**
 * Generated class for the FrontPage page.
 *
 * See https://ionicframework.com/docs/components/#navigation for more info on
 * Ionic pages and navigation.
 */

@IonicPage()
@Component({
  selector: 'page-front',
  templateUrl: 'front.html',
})
export class FrontPage {
  myInput:string;
  constructor(public navCtrl: NavController, public navParams: NavParams) {
  }

  ionViewDidLoad() {
    console.log('ionViewDidLoad FrontPage');
  }
  login(){
    this.navCtrl.push(LoginPage);
    console.log("1111");
  }
  register(){
    this.navCtrl.push(RegisterPage);
    console.log("2222");
  }
  search(){
    // this.navCtrl.push(HomePage);
    console.log(this.myInput);
    if(this.myInput!=null)
    {
      this.navCtrl.push(TabsPage);
    }
  }
}
